/**游戏世界配置 */
export default class GameWorldConfig {
  static ADQ_ENV = "dev";

  //游戏世界速率 -物体移动速度 等于物体速度/速率
  static worldSpeedRate = 50;

  //游戏帧率
  static worldFrameRate = 1;
  /**游戏舞台宽度 */
  static worldWidth = 1334;
  /**游戏舞台高度 */
  static worldHeight = 768;
  /**屏幕宽度 适配时使用此宽度适配*/
  static screenWidth = 1334;
  /**屏幕高度 适配时使用此高度适配 */
  static screenHeight = 768;
  //中心点X坐标
  static worldCenterX: number = 0;
  //中心点y坐标
  static worldCenterY: number = 0;
  static scaleRate: number = 0;
  /**初始化世界参数 */
  static initialize(
    worldW: number,
    worldH: number,
    screenW: number,
    screenH: number
  ) {
    this.scaleRate = worldW / screenW;
    this.worldWidth = worldW;
    this.worldHeight = worldH;
    this.screenWidth = screenW;
    this.screenHeight = screenH;
    this.worldCenterX = this.worldWidth >> 1;
    this.worldCenterY = this.worldHeight >> 1;
  }
}
